#pragma once
#include "GameBase.h"
#include "SubStructure.h"

class GameScene;
class BulletFactory;
class EnemyFactory;
class PCBulletFactory;
class ItemFactory;
class EffectFactory;

class Mediator : public GameBase
{
private:
	GameScene* scene;
	BulletFactory* BFactory;
	EnemyFactory* EFactory;
	PCBulletFactory* PBFactory;
	ItemFactory* IFactory;
	EffectFactory* EfFactory;

	EventList E_Queue;

	static Mediator* _p_this;
	Mediator();
public:
	void SetScene(GameScene* nscene);

	void GetEvent(EventList Elist);
	void ProcessQueue();

	void MakeBullet(EventList Elist);
	void MakeEnemy(EventList Elist);
	void MakeUserBullet(EventList Elist);
	void MakeItem(EventList Elist);
	void MakeEffect(EventList Elist);
	
	void ProcessOther(EventList Elist);

	static Mediator* Instance();
};